//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package com.zbs.framework.start.entity.tree;

import java.util.Map;

public class ResultData {
    private Long total;
    private Integer code;
    private String message;
    private Object data;

    public static ResultData build() {
        return new ResultData();
    }

    public ResultData() {
    }

    public ResultData(Long total, Object data) {
        this.total = total;
        this.data = data;
    }

    public ResultData(Object data) {
        this.data = data;
    }

    public ResultData total(Long total) {
        this.setTotal(total);
        return this;
    }

    public ResultData code(Integer code) {
        this.setCode(code);
        return this;
    }

    public ResultData message(String message) {
        this.setMessage(message);
        return this;
    }

    public ResultData data(Object value) {
        this.data = value;
        return this;
    }

    public ResultData data(Map<String, Object> data) {
        this.setData(data);
        return this;
    }

    public Long getTotal() {
        return this.total;
    }

    public Integer getCode() {
        return this.code;
    }

    public String getMessage() {
        return this.message;
    }

    public Object getData() {
        return this.data;
    }

    public void setTotal(final Long total) {
        this.total = total;
    }

    public void setCode(final Integer code) {
        this.code = code;
    }

    public void setMessage(final String message) {
        this.message = message;
    }

    public void setData(final Object data) {
        this.data = data;
    }

    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        } else if (!(o instanceof ResultData)) {
            return false;
        } else {
            ResultData other = (ResultData)o;
            if (!other.canEqual(this)) {
                return false;
            } else {
                label59: {
                    Object this$total = this.getTotal();
                    Object other$total = other.getTotal();
                    if (this$total == null) {
                        if (other$total == null) {
                            break label59;
                        }
                    } else if (this$total.equals(other$total)) {
                        break label59;
                    }

                    return false;
                }

                Object this$code = this.getCode();
                Object other$code = other.getCode();
                if (this$code == null) {
                    if (other$code != null) {
                        return false;
                    }
                } else if (!this$code.equals(other$code)) {
                    return false;
                }

                Object this$message = this.getMessage();
                Object other$message = other.getMessage();
                if (this$message == null) {
                    if (other$message != null) {
                        return false;
                    }
                } else if (!this$message.equals(other$message)) {
                    return false;
                }

                Object this$data = this.getData();
                Object other$data = other.getData();
                if (this$data == null) {
                    if (other$data != null) {
                        return false;
                    }
                } else if (!this$data.equals(other$data)) {
                    return false;
                }

                return true;
            }
        }
    }

    protected boolean canEqual(final Object other) {
        return other instanceof ResultData;
    }


    public String toString() {
        return "ResultData(total=" + this.getTotal() + ", code=" + this.getCode() + ", message=" + this.getMessage() + ", data=" + this.getData() + ")";
    }
}
